package com.agile.leetcode.designmodel.decorator;

/**
 * @Author KD
 * @Date 2021/1/11 16:44
 */
public class Decorator implements IPerson {
    // 将顶层超累聚合在里面
    public IPerson iPerson;

    public Decorator(IPerson iPerson) {
        this.iPerson = iPerson;
    }

    @Override
    public void show() {
        // 调用方法
        iPerson.show();
    }
}
